package OOday02;

/**
 * @description: TODO
 * @author yumo
 * @version: 1.0
 * @date 2025/3/7 11:57
 */
public class AnimalTest {
    public static void main(String[] args) {
        Dog dog=new Dog("小黑",18,"白色","屎");
        dog.eat();//dog重写的eat
        dog.lookhome();//dog特有的lookhome
        dog.swim();


        Chick ck=new Chick("小鸡",1,"粉色");
        ck.eat();//Chick重写的eat
        ck.drink();//父类的drink



        Fish fh=new Fish("小鱼",2,"白色");
        fh.eat();//fish中重写的eat
        fh.drink();//继承的父类的drink
        fh.swim();
    }
}
